import request from "@/utils/request";

// 获取植物分类
export function GetPlanClassTree() {
  return request({
    url: "/work/type/selectPlantPType",
    method: "post",
  });
}

// 新增植物分类
export function addPlanClassTree(data) {
  return request({
    url: "/work/type/insertPlantPType",
    method: "post",
    data,
  });
}

// 删除植物分类
export function DeletePlanClassTree(query) {
  return request({
    url: "/work/type/deleteBoundIn",
    method: "post",
    params: query,
  });
}

// 查询植物列表
export function GetPlansList(query) {
  return request({
    url: "/work/information/selectRecord",
    method: "post",
    params: query,
    headers: {
      repeatSubmit: false,
    },
  });
}

// 添加植物列表
export function addPlans(data) {
  return request({
    url: "/work/information/insertRecord",
    method: "post",
    data,
  });
}

// 修改植物列表
export function updatePlans(data) {
  return request({
    url: "/work/information/updateRecord",
    method: "post",
    data,
  });
}

// 删除植物列表
export function DeletePlans(data) {
  return request({
    url: "/work/information/deleteRecord",
    method: "post",
    data,
  });
}
